create external table jms_dim.dim_abnormal_event_report_base
(
    id                  bigint          comment                     '主键id',
    code                string  comment '异常编号',
    involved_type_id    int      comment '涉事网点类型id',
    involved_type_desc  string  comment '涉事网点类型desc',
    involved_org_id     int         comment '涉事组织id',
    involved_org_code   string    comment '涉事组织编码',
    involved_org_name   string    comment '涉事组织名称',
    involved_agent_id   int         comment '涉事组织代理区id',
    involved_agent_code string     comment '涉事组织代理区编码',
    involved_agent_name string  comment '涉事组织代理区名称',
    city_desc           string  comment '所属城市',
    area_desc           string comment '所属区县',
    abnormal_type_id    bigint       comment '异常类型id',
    abnormal_type       string   comment '异常类型',
    scene_name          string  comment '场景名称',
    report_time         timestamp comment '上报时间',
    happen_time         timestamp comment '发生时间',
    end_time            timestamp comment '结束时间',
    defer_day           smallint     comment '顺延天数',
    create_time         timestamp    comment '创建时间',
    update_time         timestamp    comment '修改时间'
)
    comment '异常事件报表'

    stored as parquet
    location '/dw/hive/jms_dim.db/external/dim_abnormal_event_report_base'
;